package com.unicom;

import java.util.HashMap;
import java.util.Iterator;
import java.util.Set;

/**
 * @author liry
 * @version 1.0
 * @date Created on 2021/11/17 14:35
 * Description:
 */
public class Application {
    public static void main(String[] args) {

        HashMap<String, Object> map = new HashMap<>();

        map.put("age", 10);
        map.put("name", "tom");
        map.put("gender", 1);

        Set<String> keys = map.keySet();
        Iterator<String> iterator = keys.iterator();
        while (iterator.hasNext()) {
            String next = iterator.next();

            Object o = map.get(next);

            System.out.println(next + "--" + o);
        }
    }
}
